package cn.newtouch.block;

import cn.newtouch.domain.User;
import com.alibaba.csp.sentinel.slots.block.BlockException;
import org.springframework.web.bind.annotation.PathVariable;

public class UserBlock {

    public static User BlockHandlerMethod(@PathVariable("id") Long id, BlockException e){
        e.printStackTrace();
        System.out.println("限流了。。。。。。。");
        return new User(-1L,"触发限流","限流了！！");
    }
}
